import socket

IP = '127.0.0.1'
PORT = 8888

def clinet():
    with socket.socket(socket.AF_INET, socket.SOCK_STREAM) as s:
        s.connect((IP, PORT))
        s.send('Hello'.encode('gbk'))
        s.send('world'.encode('gbk'))
        return

clinet()